﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Drawing;
using System.Windows.Forms;
using DevExpress.XtraEditors;
using Resources;
namespace Coffee_Controls
{
   public class MyTable :System.Windows.Forms.Button
    {
        private String tbName;

        public String TbName
        {
            get { return tbName; }
            set { tbName = value; }
        }
        private int tbID;

        public int TbID
        {
            get { return tbID; }
            set { tbID = value; }
        }
       public MyTable()
        {
          Bitmap bm = ResourceHelper.Get_Convert_BitMap(ResourceIDs.BITMAP_TABLE);
          BitmapToRegion.CreateControlRegion(this, bm);
          this.DragOver += new DragEventHandler(FrogTable_DragOver);
          this.MouseDown += new MouseEventHandler(FrogTable_MouseDown);
          this.MouseHover +=new EventHandler(MyTable_MouseHover);
           //Show Name table
          LabelControl lbName = new LabelControl();
          lbName.Text = "skjfl";
          lbName.Location = new Point(20, 20);
          this.Controls.Add(lbName);
        }
       private void FrogTable_DragOver(object sender, System.Windows.Forms.DragEventArgs e)
       {
            
           e.Effect = DragDropEffects.Move;
           
       }
       private void FrogTable_MouseDown(object sender, MouseEventArgs e)
       {
          
           this.DoDragDrop(this, DragDropEffects.Copy);
           
       }
       private void MyTable_MouseHover(object sender, System.EventArgs e)
       {

           //MessageBox.Show("lskjf");
       }
    }
}
